//
//  XWSeparatorLineBaseTBCell.swift
//  XiaoweHearingAid
//
//  Created by edy on 2024/12/12.
//

import UIKit

class XWSeparatorLineBaseTBCell: XWHBaseTBCell {
    
    lazy var separatorLine = UIView()

    override func addSubViews() {
        super.addSubViews()
        
        contentView.addSubview(separatorLine)
        
        separatorLine.isHidden = false
        separatorLine.backgroundColor = tableSeparatorColor
    }
    
    func relayoutSeparatorLine() {
        separatorLine.snp.remakeConstraints { make in
            make.top.equalToSuperview()
            make.height.equalTo(0.5)
            make.left.equalToSuperview().offset(16)
            make.right.equalToSuperview().offset(-16)
        }
        
        bringSeparatorLineViewToFront()
    }
    
    final func bringSeparatorLineViewToFront() {
        contentView.bringSubviewToFront(separatorLine)
    }
    
}
